﻿
@{
    ViewBag.Title = "About";

    Layout = null;
}

<link href="~/layer/skin/layer.css" rel="stylesheet" />
<script src="~/Scripts/jquery-3.3.1.js"></script>
<script src="~/layer/layer.js"></script>

<h2>我是About页面，你加载了我哦。惠风和畅。阴雨绵绵</h2>
<h2>西北院天一片云，@ViewBag.Id 乌鸦落在凤凰群。</h2>

<button onclick="closepage()">关闭弹窗(关闭子页面，刷新父级页面)</button>

<script>

    //关闭子页面，刷新父级页面
    function closepage() {

        //在当前iframe => 关闭当前iframe 
        var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
        parent.layer.close(index); //再执行关闭  
    }

</script>
